<?php
/**
 * 图形验证码控制器
 */

namespace App\Http\Validates\Backend;

class GroupValidate
{
    static public function setGroupPost()
    {
        return [
            'group_name' => 'required|string|between:0,20',
            'group_id' => 'required|integer|min:0',
            'description' => 'required|string|max:500'
        ];
    }

    static public function listMembersPost()
    {
        return [
            'keyword' => 'string|between:0,30',
            'page_num' => 'required|integer|min:1',
            'page_size' => 'required|integer|min:1'
        ];
    }

    static public function listGroupPost()
    {
        return [
            'keyword' => 'string|between:0,30',
            'page_num' => 'required|integer|min:1',
            'page_size' => 'required|integer|min:1'
        ];
    }

    static public function addApply()
    {
        return [
            'apply_group_id' => 'required|integer|min:1',
            'apply_reason' => 'required|string|between:1,300'
        ];
    }

    static public function delApply()
    {
        return [
            'apply_group_id' => 'required|integer|min:1',
        ];
    }

    static public function listApply()
    {
        return [
            'keyword' => 'string|between:0,30',
            'page_num' => 'required|integer|min:1',
            'page_size' => 'required|integer|min:1',
            'status' => 'integer|in:-1,1,3,4'
        ];
    }

    static public function examineApply()
    {
        return [
            'apply_id' => 'required|integer|min:1',
            'operate' => 'required|integer|in:1,2'
        ];
    }
}
